<?php
require_once "admin/dbconnector.php";
session_start();
$db = opendatabase();
$total_itens = 0;
$valor_total = 0;
?>

<style type="text/css">
	<!--
	.style1 {
		width: 535px;
		border: none;
	}
	.style2 {
		background-color: #62C502;
		font-weight: bold;
		text-align: center;
	}
	.val {
		width: 90px;
		text-align: center;
	}
	.opt {
		width: 20px;
		text-align: center;
	}
	-->
</style>

<table class="style1">
	<tr>
		<td class="style2">Descri&ccedil;&atilde;o</td>
		<td class="style2">Qtde.</td>
		<td class="style2">Pre&ccedil;o</td>
		<td class="style2">
			<img src="images/stop16.gif" alt="Excluir" />
		</td>
	</tr>
	
	<?php
	foreach($_SESSION['pedido'] as $pid) {
		$rs = mysql_query("SELECT * FROM produto WHERE id = '$pid'");
		$produto = mysql_fetch_array($rs);
		//$total_itens = $total_itens + $;
		
		echo "
			<tr>
				<td>" . strtoupper($produto["descricao"]) . "</td>
				<td></td>
				<td class='val'>" . number_format($produto["valor"]/100,2,',','.') . "</td>
				<td class='opt'><img src='images/stop16.gif' alt='Excluir Item' title='Excluir Item' /></td>
			</tr>
		";
	}
	?>
	
	
	
</table>